package net.example.model;

import net.example.utils.SerializeHelper;

import java.util.ArrayList;
import java.util.List;

import io.netty.buffer.ByteBuf;

public class AddGroupRequestPage
{
    public List<AddGroupRequest> AddGroupRequestList;
    public int TotalEntityCount ;

    public void deserialize(byte[] info) throws Exception {
        ByteBuf buffer = SerializeHelper.wrappedBuffer(info);
        buffer.readInt();
        int count = buffer.readInt();
        this.AddGroupRequestList = new ArrayList<>();
        for (int i = 0; i < count; i++) {
            AddGroupRequest addGroupRequest = new AddGroupRequest();
            addGroupRequest.deSerialize(buffer);
            this.AddGroupRequestList.add(addGroupRequest);
        }
        this.TotalEntityCount = buffer.readInt();
    }
}
